/* Copyright 2021 The LUCI Authors.
**
** Licensed under the Apache License, Version 2.0 (the "License");
** you may not use this file except in compliance with the License.
** You may obtain a copy of the License at
**
**      http://www.apache.org/licenses/LICENSE-2.0
**
** Unless required by applicable law or agreed to in writing, software
** distributed under the License is distributed on an "AS IS" BASIS,
** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
** See the License for the specific language governing permissions and
** limitations under the License.
 */

/* v2 verdicts */
.failed-verdict {
  color: var(--failure-color);
}
.execution-errored-verdict {
  color: var(--critical-failure-color);
}
.precluded-verdict {
  color: var(--precluded-color);
}
.passed-verdict {
  color: var(--success-color);
}
.skipped-verdict {
  color: var(--skipped-color);
}
.flaky-verdict {
  color: var(--warning-color);
}
span.flaky-verdict {
  color: var(--warning-text-color);
}
.exonerated-verdict {
  color: var(--exonerated-color);
}

/* v2 test results */
.failed-result {
  color: var(--failure-color);
}
.execution-errored-result {
  color: var(--critical-failure-color);
}
.precluded-result {
  color: var(--precluded-color);
}
.passed-result {
  color: var(--success-color);
}
.skipped-result {
  color: var(--skipped-color);
}

/* v1 verdicts */
.unexpected {
  color: var(--failure-color);
}
.unexpectedly-skipped {
  color: var(--critical-failure-color);
}
.flaky {
  color: var(--warning-color);
}
span.flaky {
  color: var(--warning-text-color);
}
.exonerated {
  color: var(--exonerated-color);
}
.expected {
  color: var(--success-color);
}


.scheduled {
  color: var(--scheduled-color);
}

.started {
  color: var(--started-color);
}

.success {
  color: var(--success-color);
}

.failure {
  color: var(--failure-color);
}

.infra-failure {
  color: var(--critical-failure-color);
}

.canceled {
  color: var(--canceled-color);
}

.scheduled-bg {
  border: 1px solid var(--scheduled-color);
  background-color: var(--scheduled-bg-color);
}

.started-bg {
  border: 1px solid var(--started-color);
  background-color: var(--started-bg-color);
}

.success-bg {
  border: 1px solid var(--success-color);
  background-color: var(--success-bg-color);
}

.failure-bg {
  border: 1px solid var(--failure-color);
  background-color: var(--failure-bg-color);
}

.infra-failure-bg {
  border: 1px solid var(--critical-failure-color);
  background-color: var(--critical-failure-bg-color);
}

.canceled-bg {
  border: 1px solid var(--canceled-color);
  background-color: var(--canceled-bg-color);
}

.undefined-bg-pattern {
  border: 1px solid rgba(0, 0, 0, 0);
  background-color: rgba(0, 0, 0, 0);
}

.scheduled-bg-pattern {
  border: 1px solid var(--scheduled-color);
  background-color: var(--scheduled-bg-color);
}

.started-bg-pattern {
  border: 1px solid var(--started-color);
  background-color: var(--started-bg-color);
  background-image: linear-gradient(135deg, var(--started-color) 5%, transparent 25%), linear-gradient(225deg, var(--started-color) 5%, transparent 25%), linear-gradient(45deg, var(--started-color) 5%, transparent 25%), linear-gradient(315deg, var(--started-color) 5%, var(--started-bg-color) 25%);
  background-position: 3px 0, 3px 0, 0 0, 0 0;
  background-size: 6px 6px;
  background-repeat: repeat;
}

.success-bg-pattern {
  border: 1px solid var(--success-color);
  background-color: var(--success-bg-color);
}

.failure-bg-pattern {
  border: 1px solid var(--failure-color);
  background-color: var(--failure-bg-color);
  background-size: 8px 8px;
  background-image: repeating-linear-gradient(45deg, var(--failure-color) 0, var(--failure-color) 1px, var(--failure-bg-color) 0, var(--failure-bg-color) 50%);
}

.infra-failure-bg-pattern {
  border: 1px solid var(--critical-failure-color);
  background-color: var(--critical-failure-bg-color);
  background-size: 8px 8px;
  background-image: repeating-linear-gradient(135deg, var(--critical-failure-color) 0, var(--critical-failure-color) 1px, var(--critical-failure-bg-color) 0, var(--critical-failure-bg-color) 50%);
}

.canceled-bg-pattern {
  border: 1px solid var(--canceled-color);
  background-color: var(--canceled-bg-color);
  background-image: linear-gradient(0deg, var(--canceled-bg-color) 60%, var(--light-background-color-4) 40%);
  background-size: 4px 4px;
}